<template>
  <div class="map_window" style="width: 100%;height: 100%;position: relative;">
    <map_point style="width: 100%;height: 100%;position: relative;" :point_list="point_list" :content_html="content_html"></map_point>
  </div>
</template>

<script>
export default {
  props: ['__iframe'],
  data: function(){
    var app = this;
    return {
      point_list: [],
      content_html(data){
        return `<div><p>${data.title}</p><p>${data.address}</p></div>`;
      },
    }
  },
  methods: {},
  mounted(){
    let app = this;
    if (!this.__iframe) window['app'] = this;

    ajax({url:'/admin/agent/list', cache:true},function (res){
      app.point_list = res.data.list;
      return false;
    })
  }
}
</script>

<style scoped>

</style>